package com.javablog.elasticsearch.es.entity;

import lombok.Data;

import java.util.List;

@Data
public class PageInfo<T> {
//        page.setList(list);
//        page.setPageNum(pageNum);
//        page.setPageSize(pageSize);
//        page.setTotal(total);
//        page.setPages(total== 0 ? 0: (total%pageSize == 0 ? total / pageSize : (total / pageSize) + 1));
//        page.setHasNextPage(page.getPageNum() < page.getPages());

    private List<T> list;

    private int pageNum;

    private int pageSize;

    private int total;

    private int pages;

    private boolean hasNextPage;

}
